/**********************************************************************
 Copyright (C) 2009 Jaakko Vuori

 This file is part of Cimer.
 For more information, see <http://code.google.com/p/cimer/>

 Cimer is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
 the Free Software Foundation, either version 3 of the License, or
 (at your option) any later version.

 Cimer is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 GNU General Public License for more details.

 You should have received a copy of the GNU General Public License
 along with Cimer.  If not, see <http://www.gnu.org/licenses/>.
 **********************************************************************/

#ifndef CIMERWINDOW_H
#define CIMERWINDOW_H

#include <QtGui/QMainWindow>
#include <QtCore/QDateTime>

class ScreensaverPreventer;

namespace Ui {
    class CimerWindow;
}

class CimerWindow : public QMainWindow
{
    Q_OBJECT

public:
    CimerWindow(QWidget *parent = 0);
    ~CimerWindow();

protected:
    void closeEvent(QCloseEvent* event);

protected Q_SLOTS:
    void handletimeElapsed();
    void handletimeAdjusted(int secondsLeft);
    void setTime(int minutes);
    void playAudioNotification();
    void enableSound(bool enabled);

private:
    void createMenu();

private:
    Ui::CimerWindow *ui;
    ScreensaverPreventer* m_screensaverPreventer;
    bool m_soundEnabled;
};

#endif // CIMERWINDOW_H
